import request from '@/config/axios'

export interface VideoAccountTaskVO {
  id: number
  jobId: string
  accountId: number
  duration: number
  status: number
  remark: string
}

// 查询账号解析任务列表
export const getVideoAccountTaskPage = async (params) => {
  return await request.get({ url: `/beat/video-account-task/page`, params })
}

// 查询账号解析任务详情
export const getVideoAccountTask = async (id: number) => {
  return await request.get({ url: `/beat/video-account-task/get?id=` + id })
}

// 新增账号解析任务
export const createVideoAccountTask = async (data: VideoAccountTaskVO) => {
  return await request.post({ url: `/beat/video-account-task/create`, data })
}

// 修改账号解析任务
export const updateVideoAccountTask = async (data: VideoAccountTaskVO) => {
  return await request.put({ url: `/beat/video-account-task/update`, data })
}

// 删除账号解析任务
export const deleteVideoAccountTask = async (id: number) => {
  return await request.delete({ url: `/beat/video-account-task/delete?id=` + id })
}

// 导出账号解析任务 Excel
export const exportVideoAccountTask = async (params) => {
  return await request.download({ url: `/beat/video-account-task/export-excel`, params })
}
